﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/MainMaster.Master" 
Inherits="System.Web.Mvc.ViewPage<IList<CoVanHocTapData.Entities.MonHocTheoHocKy>>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	Chương trình đào tạo chuẩn
</asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <link href="../../CSS/stylesheets/jquery.tooltip/jquery.tooltip.css" rel="stylesheet"
        type="text/css" />
    <script src="../../CSS/javascripts/jquery.min.js" type="text/javascript"></script>
    <script src="../../CSS/javascripts/jquery.tooltip.js" type="text/javascript"></script>
    <style type="text/css">
        div.item
        {
            background-color: #56738F;
            text-align: center;
            height: 65px;
            color: White;
        }
    </style>
    <script type="text/javascript">
        $j = jQuery.noConflict();
        $j(document).ready(function () {
            $j("div.item").tooltip().css({ opacity: 0.9 });
        });
    </script>
    <%if (CoVanHocTapProject.Infrastructure.Publics.sinhVienDangNhap != null && Model!=null)
  {%>
  <br />
  <div align=center>
        <label style="font-weight:bold; font-size:larger; font-family:Courier New; color:#56738F">
        Chương trình đào tạo của ngành <%=CoVanHocTapProject.Infrastructure.Publics.sinhVienDangNhap.Lop.NganhDaoTao.TenNganh %></label>
        </div>
        <br />
     <table border=1 cellpadding=0 cellspacing=0 >        
       
        <tr style="background-color:#DCDCDC; " >
            <td align="center" valign="middle" style="width:180px; height:30px;
            font-weight:bold ">HK1</td>
            <td align="center" valign="middle" style="width:180px; font-weight:bold" >HK2</td>
            <td align="center" valign="middle" style="width:180px;font-weight:bold">HK3</td>
            <td align="center" valign="middle" style="width:180px;font-weight:bold">HK4</td>
            <td align="center" valign="middle" style="width:180px;font-weight:bold">HK5</td>
            <td align="center" valign="middle" style="width:180px;font-weight:bold">HK6</td>
            <td align="center" valign="middle" style="width:180px;font-weight:bold">HK7</td>
            <td align="center" valign="middle" style="width:180px;font-weight:bold">HK8</td>
            </tr>
       
       <tr>
    <%for (int i = 0; i < 9; i++)
      {%>
                    
        <td  valign="top" align="center">
          
             <% foreach (var item in Model)
                {
                    int tempInt;
                    if (int.TryParse(item.HocKy, out tempInt))
                    {
                        if (tempInt == i + 1 && item.LaMonTuChon == false)
                        {%>             
                    
                    
                    <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                      {%>
                        
                        <div class="item">
                            <b><%= item.MonHocID%></b>          
                            <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                        <div class="tooltip_description" style="display:none" 
                        title="Môn học song hành"><%=item.MonHocSongHanh%></div>
                        </div>
                    <%} %>
                    <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
                    {%>
                            <div class="item">
                            <b ><%= item.MonHocID%></b>
                            <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                            <div class="tooltip_description" style="display:none" 
                            title="Môn học tiên quyết"><%=item.MonHocTienQuyet%></div>
                            </div>
                    <%} %>
                    <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
                    {%>
                            
                            <div class="item">
                            <b ><%= item.MonHocID%></b>
                            <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                            <div class="tooltip_description" style="display:none" 
                        title="Môn học trước"><%=item.MonHocTruoc%></div>
                        </div>
                            
                    <%} %>
                    <%else
                    {%>
                        <div  style="height:65px">
                             <b ><%= item.MonHocID%></b>
                             <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                        </div>
                        <%} %>
                    
                    
                   
                    <br /> <br />               
                    
                    <%}

                    }
                }%>
          
        </td>
      <%}
       %>
      </tr>
      <tr>
        <%for(int i=0;i<9;i++)
          {%>
            <% List<string> tenKhoituChon=new List<string>();%>
            <td  valign="middle" align="center" >
            
            <%foreach (var item in Model)
              {%>
              
               <%int tempInt;
                 if (item.HocKy!=null && int.TryParse(item.HocKy, out tempInt))
                 {
                     if (tempInt == i + 1 && item.LaMonTuChon == true)
                     {%>  
                        <table width=100% cellpadding=0 cellspacing=0 border=0 style="height:100% ;background-color:#000000; color:White; font-weight:bold;">
                            <tr>
                                <td style="text-align:center; height:30px">
                                    <div class="item" style="text-align:center">
                                        <%= item.TenKhoiMonTuChon%>
                                        <div class="tooltip_description" style="display:none; text-align:center; "
                        title="Tên khối: <%= item.TenKhoiMonTuChon %>"><span style="font-size:12px"> Xem chi tiết môn học ở khung dưới</span></div>
                                    </div>
                                </td>
                            </tr>
                        </table>
                        
                        <% break; %>
                     <%} %> 
                <%}
                 else if (item.HocKy != null && !int.TryParse(item.HocKy, out tempInt))
                 {
                     string[] hocKySplit = item.HocKy.Split(',');
                     foreach (var hocKyItem in hocKySplit)
                     {
                         if (hocKyItem != "")
                         {
                             if (hocKyItem == (i + 1).ToString())
                             {
                                 if (tenKhoituChon.Count == 0 || !tenKhoituChon.Contains(item.TenKhoiMonTuChon))
                                 {
                                     tenKhoituChon.Add(item.TenKhoiMonTuChon);%>
                                    <table width=100% cellpadding=0 cellspacing=0 border=1 style="border-color:White ;height:100% ;background-color:#000000; color:White; font-weight:bold;">
                                        <tr>
                                            <td style="text-align:center; height:30px">
                                                <div class="item" style="text-align:center">
                                                    <%= item.TenKhoiMonTuChon%>  
                                                    <div class="tooltip_description" style="display:none; text-align:center; "
                        title="Tên khối: <%= item.TenKhoiMonTuChon %>">Xem chi tiết môn học ở khung dưới</div>
                                                </div>
                                            </td>
                                        </tr>
                                    </table>
                               <%} %>
                             <% break;
                             }
                             
                         }
                     }
                                 
                      %>
                    
                <%} %>
            <%} %>
            </td>
        <%} %>
      </tr>
    </table>

    <br /> <br />

    <%if (Model.FirstOrDefault() != null)
      {%>
    <%int j = 0; %>
    <table width=100% cellspacing=10>
    <tr>
        
    
    <%foreach (var tenKhoiTuChonItem in Model.FirstOrDefault().TenKhoiMonTuChonList)
      {%>
        <% string str = "Chọn 1 nhóm";
           if (tenKhoiTuChonItem.Contains(str.ToUpper()))
           { %>
            <td>
                <table border=1 cellpadding=0 cellspacing=0 style="margin-left:20px">
                    <tr style="background-color:#DCDCDC; ">
                        <td colspan=2 align="center" valign="middle" style="width:180px; font-weight:bold; height:30px">
                        <%=tenKhoiTuChonItem%></td>
                    </tr>
                    <tr>
                        <%List<string> monHocCungNhomList = new List<string>();%>
                        <%int temp = 0; %>
                        <%foreach (var item in Model)
                          {
                              if(item.CungNhom!=null)
                                temp = item.CungNhom.Value;
                              if (item.TenKhoiMonTuChon != null && item.TenKhoiMonTuChon.Equals(tenKhoiTuChonItem))
                              {%>
                                <%if (item.CungNhom.Value ==temp)
                                  {%>
                                    <td>
                                        <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                                          {%>
                        
                                            <div class="item">
                                                <b  s><%= item.MonHocID%></b>          
                                                <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                            <div class="tooltip_description" style="display:none" 
                                            title="Môn học song hành"><%=item.MonHocSongHanh%></div>
                                            </div>
                                        <%} %>
                                        <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
        {%>
                                            <div class="item">
                                            <b  ><%= item.MonHocID%></b>
                                            <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                            <div class="tooltip_description" style="display:none;" 
                                            title="Môn học tiên quyết"><%=item.MonHocTienQuyet%></div>
                                            </div>
                                    <%} %>
                                    <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
        {%>
                            
                                            <div class="item">
                                            <b  ><%= item.MonHocID%></b>
                                            <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                            <div class="tooltip_description" style="display:none; " 
                                        title="Môn học trước"><%=item.MonHocTruoc%></div>
                                        </div>
                            
                                    <%} %>
                                    <%else
        {%>
                                        <div style="height:50px;" align="center" >
                                             <b > <%= item.MonHocID%></b>
                                             <div align="center" style="font-size:12px" ><%= item.TenMonHoc%></div>
                                        </div>
                                        <%} %>
                                    </td>
                                    <tr>
                                        
                                    
                                <%}
                                  else
                                  {
                                      string addList = "<div align='center' ><b>" + item.MonHocID + "</b></div><div align='center ' style='font-size:12px'>" + item.TenMonHoc + "</div>";
                                      monHocCungNhomList.Add(addList);%>
                                    
                                <%} %>
                                <%} %>
                        <%} %>
                    </tr>
                    <tr>
                        <%if (monHocCungNhomList.Count > 0)
                          {%>
                            <td>
                             <% foreach (var monHocItem in monHocCungNhomList)
                                {%>
                                <%= monHocItem%>
                          <%} %>
                            </td>
                        <%} %>
                    </tr>
                </table>
            </td>
          <%}
           else
           { %>
        <%int i = 0; %>
        <% if (j < 2)
           {
               j++;%>
          
               <td> 
                
        <%}
           else
           {
               j = 0;%>
           <br /><br />
           </tr>
           <tr>
            <td>
        <%} %>
                

        <table border=1 cellpadding=0 cellspacing=0 style="margin-left:20px">
            <tr style="background-color:#DCDCDC; ">
                <td colspan=2 align="center" valign="middle" style="width:180px; font-weight:bold; height:30px">
                <%=tenKhoiTuChonItem%></td>
            </tr>
            <tr>
            <%foreach (var item in Model)
              {%>
                <%if (item.TenKhoiMonTuChon != null && item.TenKhoiMonTuChon.Equals(tenKhoiTuChonItem))
                  {%>
                    <%if (i < 2)
                      {%>
                        <td align="center" valign="middle">
                            <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                              {%>
                        
                                <div class="item">
                                    <b><%= item.MonHocID%></b>          
                                    <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display:none; "
                                title="Môn học song hành"><%=item.MonHocSongHanh%></div>
                                </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
        {%>
                                    <div class="item">
                                    <b ><%= item.MonHocID%></b>
                                    <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                    <div class="tooltip_description" style="display:none; " 
                                    title="Môn học tiên quyết"><%=item.MonHocTienQuyet%></div>
                                    </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
        {%>
                            
                                    <div class="item">
                                    <b ><%= item.MonHocID%></b>
                                    <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                    <div class="tooltip_description" style="display:none;" 
                                title="Môn học trước"><%=item.MonHocTruoc%></div>
                                </div>
                            
                            <%} %>
                            <%else
        {%>
                                <div style="height:50px">
                                     <b><%= item.MonHocID%></b>
                                     <div align="center" style="font-size:12px" ><%= item.TenMonHoc%></div>
                                </div>
                                <%} %>
                        
                           <%-- <br />
                            <%= item.TenMonHoc%>--%>
                            <%i++; %>
                        </td>
                    <%}
                      else
                      { %>
                        </tr>
                        <tr>
                        <%i = 0; %>
                        <td align="center" valign="middle">
                            <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                              {%>
                        
                                <div class="item">
                                    <b><%= item.MonHocID%></b>          
                                    <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display:none;" 
                                title="Môn học song hành"><%=item.MonHocSongHanh%></div>
                                </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
        {%>
                                    <div class="item">
                                    <b><%= item.MonHocID%></b>
                                    <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                    <div class="tooltip_description" style="display:none;" 
                                    title="Môn học tiên quyết"><%=item.MonHocTienQuyet%></div>
                                    </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
        {%>
                            
                                    <div class="item">
                                    <b><%= item.MonHocID%></b>
                                    <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                    <div class="tooltip_description" style="display:none;" 
                                title="Môn học trước"><%=item.MonHocTruoc%></div>
                                </div>
                            
                            <%} %>
                            <%else
        {%>
                                <div style="height:50px; font-size:12px">
                                     <b><%= item.MonHocID%></b>
                                     <div align="center"  ><%= item.TenMonHoc%></div>
                                </div>
                                <%} %>
                            <%i++; %>
                        </td>
                    <%} %>
                <%} %>
                
            <%} %>
            </tr>
        </table>
        <%} %>
        </td>
    

    <%} %>
   
    </tr>
    </table> 
    <%} %>
<%} %>

    <%--<%if (CoVanHocTapProject.Infrastructure.Publics.sinhVienDangNhap != null && Model != null)
      {%>
    <table border="1" cellpadding="0" cellspacing="0">
        <tr style="background-color: #DCDCDC;">
            <td align="center" valign="middle" style="width: 180px; height: 30px; font-weight: bold">
                HK1
            </td>
            <td align="center" valign="middle" style="width: 180px; font-weight: bold">
                HK2
            </td>
            <td align="center" valign="middle" style="width: 180px; font-weight: bold">
                HK3
            </td>
            <td align="center" valign="middle" style="width: 180px; font-weight: bold">
                HK4
            </td>
            <td align="center" valign="middle" style="width: 180px; font-weight: bold">
                HK5
            </td>
            <td align="center" valign="middle" style="width: 180px; font-weight: bold">
                HK6
            </td>
            <td align="center" valign="middle" style="width: 180px; font-weight: bold">
                HK7
            </td>
            <td align="center" valign="middle" style="width: 180px; font-weight: bold">
                HK8
            </td>
        </tr>
        <tr>
            <%for (int i = 0; i < 9; i++)
              {%>
            <td valign="top" align="center">
                <% foreach (var item in Model)
                   {
                       int tempInt;
                       if (int.TryParse(item.HocKy, out tempInt))
                       {
                           if (tempInt == i + 1 && item.LaMonTuChon == false)
                           {%>
                <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                  {%>
                <div class="item">
                    <b>
                        <%= item.MonHocID%></b>
                    <div align="center" style="font-size: 12px">
                        <%= item.TenMonHoc%></div>
                    <div class="tooltip_description" style="display: none" title="Môn học song hành">
                        <%=item.MonHocSongHanh%></div>
                </div>
                <%} %>
                <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
                    {%>
                <div class="item">
                    <b>
                        <%= item.MonHocID%></b>
                    <div align="center" style="font-size: 12px">
                        <%= item.TenMonHoc%></div>
                    <div class="tooltip_description" style="display: none" title="Môn học tiên quyết">
                        <%=item.MonHocTienQuyet%></div>
                </div>
                <%} %>
                <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
                    {%>
                <div class="item">
                    <b>
                        <%= item.MonHocID%></b>
                    <div align="center" style="font-size: 12px">
                        <%= item.TenMonHoc%></div>
                    <div class="tooltip_description" style="display: none" title="Môn học trước">
                        <%=item.MonHocTruoc%></div>
                </div>
                <%} %>
                <%else
                    {%>
                <div style="height: 65px">
                    <b>
                        <%= item.MonHocID%></b>
                    <div align="center" style="font-size: 12px">
                        <%= item.TenMonHoc%></div>
                </div>
                <%} %>
                <br />
                <br />
                <%}

                    }
                }%>
            </td>
            <%}
            %>
        </tr>
        <tr>
            <%for (int i = 0; i < 9; i++)
              {%>
              
               <%int tempInt;
                 if (item.HocKy!=null && int.TryParse(item.HocKy, out tempInt))
                 {
                     if (tempInt == i + 1 && item.LaMonTuChon == true)
                     {%>  
                        <table width=100% cellpadding=0 cellspacing=0 border=0 style="height:100% ;background-color:#000000; color:White; font-weight:bold;">
                            <tr>
                                <td style="text-align:center; height:30px">
                                    <div class="item" style="text-align:center">
                                        <%= item.TenKhoiMonTuChon%>
                                        <div class="tooltip_description" style="display:none; text-align:center; "
                        title="Tên khối: <%= item.TenKhoiMonTuChon %>"><span style="font-size:12px"> Xem chi tiết môn học ở khung dưới</span></div>
                                    </div>
                                </td>
                            </tr>
                        </table>
                        
                        <% break; %>
                     <%} %> 
            <% List<string> tenKhoituChon = new List<string>();%>
            <td valign="middle" align="center">
                <%foreach (var item in Model)
                  {%>
                <%int tempInt;
                  if (int.TryParse(item.HocKy, out tempInt))
                  {
                      if (tempInt == i + 1 && item.LaMonTuChon == true)
                      {%>
                <table width="100%" cellpadding="0" cellspacing="0" border="0" style="height: 100%;
                    background-color: #000000; color: White; font-weight: bold;">
                    <tr>
                        <td style="text-align: center; height: 30px">
                            <div class="item" style="text-align: center">
                                <%= item.TenKhoiMonTuChon%>
                                <div class="tooltip_description" style="display: none; text-align: center;" title="Tên khối: <%= item.TenKhoiMonTuChon %>">
                                    <span style="font-size: 12px">Xem chi tiết môn học ở khung dưới</span></div>
                            </div>
                        </td>
                    </tr>
                </table>
                <% break; %>
                <%} %>
                <%}
                 else if (item.HocKy != null && !int.TryParse(item.HocKy, out tempInt))
                 {
                     string[] hocKySplit = item.HocKy.Split(',');
                     foreach (var hocKyItem in hocKySplit)
                     {
                         if (hocKyItem != "")
                         {
                             if (hocKyItem == (i + 1).ToString())
                             {
                                 if (tenKhoituChon.Count == 0 || !tenKhoituChon.Contains(item.TenKhoiMonTuChon))
                                 {
                                     tenKhoituChon.Add(item.TenKhoiMonTuChon);%>
                <table width="100%" cellpadding="0" cellspacing="0" border="1" style="border-color: White;
                    height: 100%; background-color: #000000; color: White; font-weight: bold;">
                    <tr>
                        <td style="text-align: center; height: 30px">
                            <div class="item" style="text-align: center">
                                <%= item.TenKhoiMonTuChon%>
                                <div class="tooltip_description" style="display: none; text-align: center;" title="Tên khối: <%= item.TenKhoiMonTuChon %>">
                                    Xem chi tiết môn học ở khung dưới</div>
                            </div>
                        </td>
                    </tr>
                </table>
                <%} %>
                <% break;
                             }

                         }
                     }
                                 
                %>
                <%} %>
                <%} %>
            </td>
            <%} %>
        </tr>
    </table>
    <br />
    <br />
    <%if (Model.FirstOrDefault() != null)
      {%>
    <%int j = 0; %>
    <table width="100%" cellspacing="10">
        <tr>
            <%foreach (var tenKhoiTuChonItem in Model.FirstOrDefault().TenKhoiMonTuChonList)
              {%>
            <% string str = "Chọn 1 nhóm";
               if (tenKhoiTuChonItem.Contains(str.ToUpper()))
               { %>
            <td>
                <table border="1" cellpadding="0" cellspacing="0" style="margin-left: 20px">
                    <tr style="background-color: #DCDCDC;">
                        <td colspan="2" align="center" valign="middle" style="width: 180px; font-weight: bold;
                            height: 30px">
                            <%=tenKhoiTuChonItem%>
                        </td>
                    </tr>
                    <tr>
                        <%List<string> monHocCungNhomList = new List<string>();%>
                        <%int temp = 0; %>
                        <%foreach (var item in Model)
                          {
                              if(item.CungNhom!=null)
                                temp = item.CungNhom.Value;
                              if (item.TenKhoiMonTuChon != null && item.TenKhoiMonTuChon.Equals(tenKhoiTuChonItem))
                              {%>
                        <%if (!item.CungNhom.Value)
                                <%if (item.CungNhom.Value ==temp)
                                  {%>
                                    <td>
                                        <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                                          {%>
                        
                                            <div class="item">
                                                <b  s><%= item.MonHocID%></b>          
                                                <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                            <div class="tooltip_description" style="display:none" 
                                            title="Môn học song hành"><%=item.MonHocSongHanh%></div>
                                            </div>
                                        <%} %>
                                        <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
        {%>
                                            <div class="item">
                                            <b  ><%= item.MonHocID%></b>
                                            <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                            <div class="tooltip_description" style="display:none;" 
                                            title="Môn học tiên quyết"><%=item.MonHocTienQuyet%></div>
                                            </div>
                                    <%} %>
                                    <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
        {%>
                            
                                            <div class="item">
                                            <b  ><%= item.MonHocID%></b>
                                            <div align="center"  style="font-size:12px"><%= item.TenMonHoc%></div>
                                            <div class="tooltip_description" style="display:none; " 
                                        title="Môn học trước"><%=item.MonHocTruoc%></div>
                                        </div>
                            
                                    <%} %>
                                    <%else
        {%>
                                        <div style="height:50px;" align="center" >
                                             <b > <%= item.MonHocID%></b>
                                             <div align="center" style="font-size:12px" ><%= item.TenMonHoc%></div>
                                        </div>
                                        <%} %>
                                    </td>
                                    <tr>
                                        
                                    
                                <%}
                                  else
                                  {
                                      string addList = "<div align='center' ><b>" + item.MonHocID + "</b></div><div align='center ' style='font-size:12px'>" + item.TenMonHoc + "</div>";
                                      monHocCungNhomList.Add(addList);%>
                                    
                                <%} %>
                                <%} %>
                        <%} %>
                    </tr>
                    <tr>
                        <%if (monHocCungNhomList.Count > 0)
                          {%>
                        <td>
                            <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                              {%>
                            <div class="item">
                                <b s>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none" title="Môn học song hành">
                                    <%=item.MonHocSongHanh%></div>
                            </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
                                {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học tiên quyết">
                                    <%=item.MonHocTienQuyet%></div>
                            </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
                                {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học trước">
                                    <%=item.MonHocTruoc%></div>
                            </div>
                            <%} %>
                            <%else
                                {%>
                            <div style="height: 50px;" align="center">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                            </div>
                            <%} %>
                        </td>
                        <tr>
                            <%}
                          else
                          {
                              string addList = "<div align='center' ><b>" + item.MonHocID + "</b></div><div align='center ' style='font-size:12px'>" + item.TenMonHoc + "</div>";
                              monHocCungNhomList.Add(addList);%>
                            <%} %>
                            <%} %>
                            <%} %>
                        </tr>
                        <tr>
                            <%if (monHocCungNhomList.Count > 0)
                              {%>
                            <td>
                                <% foreach (var monHocItem in monHocCungNhomList)
                                   {%>
                                <%= monHocItem%>
                                <%} %>
                            </td>
                            <%} %>
                        </tr>
                </table>
            </td>
            <%}
           else
           { %>
            <%int i = 0; %>
            <% if (j < 2)
               {
                   j++;%>
            <td>
                <%}
               else
               {
                   j = 0;%>
                <br />
                <br />
        </tr>
        <tr>
            <td>
                <%} %>
                <table border="1" cellpadding="0" cellspacing="0" style="margin-left: 20px">
                    <tr style="background-color: #DCDCDC;">
                        <td colspan="2" align="center" valign="middle" style="width: 180px; font-weight: bold;
                            height: 30px">
                            <%=tenKhoiTuChonItem%>
                        </td>
                    </tr>
                    <tr>
                        <%foreach (var item in Model)
                          {%>
                        <%if (item.TenKhoiMonTuChon != null && item.TenKhoiMonTuChon.Equals(tenKhoiTuChonItem))
                          {%>
                        <%if (i < 2)
                          {%>
                        <td align="center" valign="middle">
                            <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                              {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học song hành">
                                    <%=item.MonHocSongHanh%></div>
                            </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
                                {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học tiên quyết">
                                    <%=item.MonHocTienQuyet%></div>
                            </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
                                {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học trước">
                                    <%=item.MonHocTruoc%></div>
                            </div>
                            <%} %>
                            <%else
                                {%>
                            <div style="height: 50px">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                            </div>
                            <%} %>
                            
                            <%i++; %>
                        </td>
                        <%}
                          else
                          { %>
                    </tr>
                    <tr>
                        <%i = 0; %>
                        <td align="center" valign="middle">
                            <%if (!String.IsNullOrEmpty(item.MonHocSongHanh))
                              {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học song hành">
                                    <%=item.MonHocSongHanh%></div>
                            </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTienQuyet))
                                {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học tiên quyết">
                                    <%=item.MonHocTienQuyet%></div>
                            </div>
                            <%} %>
                            <%else if (!String.IsNullOrEmpty(item.MonHocTruoc))
                                {%>
                            <div class="item">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center" style="font-size: 12px">
                                    <%= item.TenMonHoc%></div>
                                <div class="tooltip_description" style="display: none;" title="Môn học trước">
                                    <%=item.MonHocTruoc%></div>
                            </div>
                            <%} %>
                            <%else
                                {%>
                            <div style="height: 50px; font-size: 12px">
                                <b>
                                    <%= item.MonHocID%></b>
                                <div align="center">
                                    <%= item.TenMonHoc%></div>
                            </div>
                            <%} %>
                            <%i++; %>
                        </td>
                        <%} %>
                        <%} %>
                        <%} %>
                    </tr>
                </table>
                <%} %>
            </td>
            <%} %>
        </tr>
    </table>
    <%} %>
    <%} %>--%>
    <br />
    <br />
</asp:Content>
